package com.finace.money.ui.activity;

import android.view.View;
import android.widget.RelativeLayout;
import android.widget.TextView;

import com.finace.money.R;
import com.finace.money.common.util.ACache;
import com.finace.money.common.util.LogUtil;
import com.finace.money.common.util.UIUtil;
import com.finace.money.di.component.AppComponent;
import com.finace.money.net.socket.PushReceiver;

import java.util.List;

import butterknife.BindView;

/**
 * Created by zhangpeng on 2017/11/28.
 */

public class SettleAccountActivity extends BaseActivity {
    @BindView(R.id.tv_content)
    TextView tvContent;
    @BindView(R.id.rl_left)
    RelativeLayout rlLeft;
    @BindView(R.id.tv_head_title)
    TextView tvHeadTitle;

    @Override
    public int setLayout() {
        return R.layout.activity_settle_account;
    }

    @Override
    public void init() {

        tvHeadTitle.setText(UIUtil.getString(R.string.settle_account_list));
        List<String> contents = (List<String>) ACache.get(UIUtil.getContext()).getAsObject(PushReceiver.QRY_SETTLEINFO_END);
        StringBuilder stringBuilder = new StringBuilder();
        for (String s :contents) {
            stringBuilder.append(s);
        }
        LogUtil.d("content",stringBuilder.toString());
        tvContent.setText(stringBuilder.toString());
        rlLeft.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                onBackPressed();
            }
        });
    }

    @Override
    public void setupAcitivtyComponent(AppComponent appComponent) {

    }

}
